<template>
  <!-- 详情 -->
  <el-dialog title="进出境政策及指引详情" :visible.sync="dialogVisible" width="50%" append-to-body :close-on-click-modal="false" :before-close="closedialog">
       <el-descriptions :column="2"  border>
		 <el-descriptions-item>
		        <template slot="label">
		         公告标题
		        </template>
		       {{form.noticeTitle}}
		  </el-descriptions-item>
		  <el-descriptions-item>
		        <template slot="label">
		         公告类型
		        </template>
		        <dict-tag :options="dict.type.ie_policy_guid_type" :value="form.noticeType"/>
		  </el-descriptions-item>
		 <el-descriptions-item>
		        <template slot="label">
		         公告内容
		        </template>
		       {{form.noticeContent}}
		  </el-descriptions-item>
		  <el-descriptions-item>
		        <template slot="label">
		         公告状态
		        </template>
		        <dict-tag :options="dict.type.start_stop_status" :value="form.status"/>
		  </el-descriptions-item>
		 <el-descriptions-item>
		        <template slot="label">
		         点击量
		        </template>
		       {{form.clicks}}
		  </el-descriptions-item>
		 <el-descriptions-item>
		        <template slot="label">
		         附件
		        </template>
		       {{form.fileUrl}}
		  </el-descriptions-item>
		 <el-descriptions-item>
		        <template slot="label">
		         创建者
		        </template>
		       {{form.createBy}}
		  </el-descriptions-item>
		 <el-descriptions-item>
		        <template slot="label">
		         创建时间
		        </template>
		       {{form.createTime}}
		  </el-descriptions-item>
		 <el-descriptions-item>
		        <template slot="label">
		         更新者
		        </template>
		       {{form.updateBy}}
		  </el-descriptions-item>
		 <el-descriptions-item>
		        <template slot="label">
		         更新时间
		        </template>
		       {{form.updateTime}}
		  </el-descriptions-item>
		 <el-descriptions-item>
		        <template slot="label">
		         备注
		        </template>
		       {{form.remark}}
		  </el-descriptions-item>
         </el-descriptions>
        <div slot="footer" class="dialog-footer" style="text-align: center;">
          <el-button @click="closedialog">关闭</el-button>
        </div>
    </el-dialog>
</template>

<script>
import { getNoticeInfo } from "@/api/miniapp/noticeInfoGuid";
export default {
  props: {
    dict: {}
  },
  data() {
    return {
      //显示详情
      dialogVisible:false,
      form: {
                                      id: null,
                                            noticeTitle: null,
                                            noticeType: null,
                                            noticeContent: null,
                                        status: "0",
                                            clicks: null,
                                            fileUrl: null,
                                            createBy: null,
                                            createTime: null,
                                            updateBy: null,
                                            updateTime: null,
                                            remark: null
                      }
    }
  },
  methods: {
    open(row){
      this.dialogVisible = true;
      this.loadDetail(row);
    },
    closedialog(){
      this.dialogVisible = false
    },
    // 获取详情
    loadDetail(row) {
      getNoticeInfo(row.id).then((res) => {
        if (res.code == 200) {
          this.form = res.data;
                  }
      });
    },
  }
};
</script>

<style>

</style>
